<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<ui:composition template="/WEB-INF/templates/template.xhtml"
	xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:a4j="http://richfaces.org/a4j"
	xmlns:rich="http://richfaces.org/rich">

	<ui:define name="content">
		<h:messages globalOnly="true" />
		<div id="stylized" class="myform">
			<h:form>
				<h1>Sign-up form</h1>
				<p>This is the basic look of my form without table</p>
				<h:panelGrid columns="3">
					<h:outputLabel for="firstName" value="First Name" />
					<h:inputText id="firstName" value="#{userBean.user.firstName}"
						required="true" />
					<h:message for="firstName" />
					<h:outputLabel for="lastName" value="Last Name" />
					<h:inputText id="lastName" value="#{userBean.user.lastName}"
						required="true" />
					<h:message for="lastName" />
					<h:outputLabel for="login" value="Login" />
					<h:inputText id="login" value="#{userBean.user.login}"
						required="true" />
					<h:message for="login" />
					<h:outputLabel for="password" value="Password" />
					<h:inputSecret id="password" value="#{userBean.user.password}"
						required="true" />
					<h:message for="password" />
					<h:outputLabel for="role" value="Role" />
					<rich:select id="role" value="#{userBean.user.role}"
						required="true">
						<f:selectItem itemLabel="-Select-" noSelectionOption="true" />
						<f:selectItem itemValue="Administrator" itemLabel="Administrator" />
						<f:selectItem itemValue="Simple User" itemLabel="Simple User" />
					</rich:select>
					<h:message for="role" />
					<h:commandButton action="#{register.createUser(userBean.user)}"
						value="Register"
						style="width : 150px;; margin-top : 20px; margin-left : 20px; height : 30px;" />
				</h:panelGrid>
			</h:form>
		</div>
	</ui:define>
	<ui:define name="footer">
	</ui:define>
</ui:composition>